package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.common.annotation.DataSource;
import com.ruoyi.common.enums.DataSourceType;

import com.ruoyi.system.mapper.api.WCoinMapper;
import com.ruoyi.system.domain.api.WCoin;
import com.ruoyi.system.service.IWCoinService;

/**
 * 币种配置Service业务层处理
 * 
 * @author ruoyi
 * @date 2022-04-22
 */
@DataSource(DataSourceType.SLAVE)
@Service
public class WCoinServiceImpl implements IWCoinService 
{
    @Autowired
    private WCoinMapper wCoinMapper;

    /**
     * 查询币种配置
     * 
     * @param id 币种配置主键
     * @return 币种配置
     */
    @Override
    public WCoin selectWCoinById(Long id)
    {
        return wCoinMapper.selectWCoinById(id);
    }

    /**
     * 查询币种配置列表
     * 
     * @param wCoin 币种配置
     * @return 币种配置
     */
    @Override
    public List<WCoin> selectWCoinList(WCoin wCoin)
    {
        return wCoinMapper.selectWCoinList(wCoin);
    }

    /**
     * 新增币种配置
     * 
     * @param wCoin 币种配置
     * @return 结果
     */
    @Override
    public int insertWCoin(WCoin wCoin)
    {
        return wCoinMapper.insertWCoin(wCoin);
    }

    /**
     * 修改币种配置
     * 
     * @param wCoin 币种配置
     * @return 结果
     */
    @Override
    public int updateWCoin(WCoin wCoin)
    {
        return wCoinMapper.updateWCoin(wCoin);
    }

    /**
     * 批量删除币种配置
     * 
     * @param ids 需要删除的币种配置主键
     * @return 结果
     */
    @Override
    public int deleteWCoinByIds(Long[] ids)
    {
        return wCoinMapper.deleteWCoinByIds(ids);
    }

    /**
     * 删除币种配置信息
     * 
     * @param id 币种配置主键
     * @return 结果
     */
    @Override
    public int deleteWCoinById(Long id)
    {
        return wCoinMapper.deleteWCoinById(id);
    }
}
